/**
 * 红绿灯预警
 */

package com.example.comm.pojo;

import lombok.Data;

@Data
public class LightWarnFlag {

    private static LightWarnFlag warnFlag ;

    private LightWarnFlag(){}


    //在调用时，没有调用过就初始化并返回对象，已调用就赋予新的经纬度并返回对象
    public static LightWarnFlag getInstance() {
        if (warnFlag == null) {
            warnFlag = new LightWarnFlag();
        }
            return warnFlag;

    }



    private int flag;

    public int getFlag() {
        return flag;
    }

    public void setFlag(int flag) {
        this.flag = flag;
    }
}
